package com.qzl.common.exception;

import com.qzl.common.common.RespConstant;

/**
 * @author: qzl
 * @date : 2025/6/23 15:28
 * @description: 聊天异常
 */
public class ChatException extends RuntimeException{
    private final int code;
    public ChatException(int code, String message) {
        super(message);
        this.code = code;
    }

    public int getCode() {
        return code;
    }
    public ChatException(RespConstant respConstant) {
        super(respConstant.getMessage());
        this.code = respConstant.getCode();
    }

}
